﻿
namespace Dev_house_Project.Providers.SynchronizationProviders
{
    public class DefaultSynchronizationProvider
    {
        #region Fields
        
        //private LocalCacheSyncAgent _syncAgent;
        //private LocalCacheClientSyncProvider _clientSyncProvider;

        #endregion

        #region Constructors 
       
        /// <summary>
        /// Default constructor.
        /// </summary>
        public DefaultSynchronizationProvider()
        {
            //_syncAgent = new LocalCacheSyncAgent();
            //_clientSyncProvider =  (LocalCacheClientSyncProvider) _syncAgent.LocalProvider;

            //_clientSyncProvider.ApplyChangeFailed += ClientSyncProviderApplyChangeFailed;
        }

        #endregion

        #region Methods
        
        /// <summary>
        /// This method resolve conflicts.
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        static void ClientSyncProviderApplyChangeFailed(object sender, Microsoft.Synchronization.Data.ApplyChangeFailedEventArgs e)
        {
            e.Action = Microsoft.Synchronization.Data.ApplyAction.Continue;
        }

        /// <summary>
        /// Synchronize data.
        /// </summary>
        public void Synchronize()
        {
            //_syncAgent.Synchronize();
        }

        #endregion
    }
}